package edu.java.texbooks.scjp.threads.test13.SCJPbook;

public class Account {

	// --- Instance variables --------------------------------------------------
	private int balance = 50;

	// --- Constructors --------------------------------------------------------
	public Account(int balance) {
		this.balance = balance;
	}

	public Account() {
		this(50);
	}

	// --- Getter and Setters --------------------------------------------------
	public int getBalance() {
		return balance;
	}

	// --- Methods -------------------------------------------------------------
	public void withdraw(int amount) {
		balance = balance - amount;
	}
}
